home *** CD-ROM | disk | FTP | other *** search
- -- card: 5147 from stack: in
- -- bmap block id: 0
- -- flags: 0000
- -- background id: 2518
- -- name:
-
-
- -- part 3 (button)
- -- low flags: 00
- -- high flags: 8003
- -- rect: left=354 top=102 right=139 bottom=468
- -- title width / last selected line: 0
- -- icon id / first selected line: 0 / 0
- -- text alignment: 1
- -- font id: 0
- -- text size: 12
- -- style flags: 0
- -- line height: 16
- -- part name: Next Problem
- ----- HyperTalk script -----
- on mouseUp
- if field "Flag" = 0 then exit mouseUp
- show button "Smiley"
- show button "Frowney"
- put empty into field "Comment"
- put " " into field "Addend1"
- put " " into field "Addend2"
- put empty into field "Sum"
- if field "Attempts" = second word of bkgnd field "Options" then
- put field "Attempts" into attempts
- put field "Correct" into correct
- put field "Percent" into percent
- put field "Name" into name
- put third word of field "Options" into skill
- put "O" into field "Attempts"
- put "O" into field "Correct"
- put "O" into field "Percent"
- set the lockScreen to true
- set the cursor to 4
- go to first card of bkgnd "Users"
- rotateData
- put name into line 1 of field "name"
- put the date into line 1 of field "Date"
- put skill into line 1 of field "Skill"
- put attempts into line 1 of field "Attempts"
- put correct into line 1 of field "Correct"
- put percent into line 1 of field "Percent"
- pop card
- exit mouseUp
- end if
- get the random of 9
- put it into char 1 of field "Addend1"
- get the random of 10
- subtract 1 from it
- put it into char 1 of field "Addend2"
- put field "Addend1" into answer
- add field "Addend2" to answer
- -- if answer < 10 then put " " into field "Sum"
- put "0" into field "Flag"
- end mouseUp
-
- on rotateData
- repeat with x = 11 down to 1
- if line x of field "Name" is empty then next repeat
- put x into nextLine
- add 1 to nextLine
- get line x of field "Name"
- put it into line nextLine of field "Name"
- get line x of field "Date"
- put it into line nextLine of field "Date"
- get line x of field "Skill"
- put it into line nextLine of field "Skill"
- get line x of field "Attempts"
- put it into line nextLine of field "Attempts"
- get line x of field "Correct"
- put it into line nextLine of field "Correct"
- get line x of field "Percent"
- put it into line nextLine of field "Percent"
- end repeat
- end rotateData
-
-
-
-
- -- part 4 (button)
- -- low flags: 00
- -- high flags: 8003
- -- rect: left=355 top=161 right=194 bottom=388
- -- title width / last selected line: 0
- -- icon id / first selected line: 0 / 0
- -- text alignment: 1
- -- font id: 0
- -- text size: 12
- -- style flags: 0
- -- line height: 16
- -- part name: 7
- ----- HyperTalk script -----
- on mouseUp
- get the length of field "Sum"
- if it is 2 then exit mouseUp
- add 1 to it
- put "7" into char it of field "Sum"
- end mouseUp
-
-
-
- -- part 5 (button)
- -- low flags: 00
- -- high flags: 8003
- -- rect: left=395 top=161 right=194 bottom=427
- -- title width / last selected line: 0
- -- icon id / first selected line: 0 / 0
- -- text alignment: 1
- -- font id: 0
- -- text size: 12
- -- style flags: 0
- -- line height: 16
- -- part name: 8
- ----- HyperTalk script -----
- on mouseUp
- get the length of field "Sum"
- if it is 2 then exit mouseUp
- add 1 to it
- put "8" into char it of field "Sum"
- end mouseUp
-
-
-
- -- part 6 (button)
- -- low flags: 00
- -- high flags: 8003
- -- rect: left=435 top=162 right=194 bottom=467
- -- title width / last selected line: 0
- -- icon id / first selected line: 0 / 0
- -- text alignment: 1
- -- font id: 0
- -- text size: 12
- -- style flags: 0
- -- line height: 16
- -- part name: 9
- ----- HyperTalk script -----
- on mouseUp
- get the length of field "Sum"
- if it is 2 then exit mouseUp
- add 1 to it
- put "9" into char it of field "Sum"
- end mouseUp
-
-
-
- -- part 7 (button)
- -- low flags: 00
- -- high flags: 8003
- -- rect: left=356 top=201 right=233 bottom=389
- -- title width / last selected line: 0
- -- icon id / first selected line: 0 / 0
- -- text alignment: 1
- -- font id: 0
- -- text size: 12
- -- style flags: 0
- -- line height: 16
- -- part name: 4
- ----- HyperTalk script -----
- on mouseUp
- get the length of field "Sum"
- if it is 2 then exit mouseUp
- add 1 to it
- put "4" into char it of field "Sum"
- end mouseUp
-
-
-
- -- part 8 (button)
- -- low flags: 00
- -- high flags: 8003
- -- rect: left=395 top=202 right=234 bottom=428
- -- title width / last selected line: 0
- -- icon id / first selected line: 0 / 0
- -- text alignment: 1
- -- font id: 0
- -- text size: 12
- -- style flags: 0
- -- line height: 16
- -- part name: 5
- ----- HyperTalk script -----
- on mouseUp
- get the length of field "Sum"
- if it is 2 then exit mouseUp
- add 1 to it
- put "5" into char it of field "Sum"
- end mouseUp
-
-
-
- -- part 9 (button)
- -- low flags: 00
- -- high flags: 8003
- -- rect: left=435 top=201 right=233 bottom=466
- -- title width / last selected line: 0
- -- icon id / first selected line: 0 / 0
- -- text alignment: 1
- -- font id: 0
- -- text size: 12
- -- style flags: 0
- -- line height: 16
- -- part name: 6
- ----- HyperTalk script -----
- on mouseUp
- get the length of field "Sum"
- if it is 2 then exit mouseUp
- add 1 to it
- put "6" into char it of field "Sum"
- end mouseUp
-
-
-
- -- part 10 (button)
- -- low flags: 00
- -- high flags: 8003
- -- rect: left=356 top=242 right=274 bottom=389
- -- title width / last selected line: 0
- -- icon id / first selected line: 0 / 0
- -- text alignment: 1
- -- font id: 0
- -- text size: 12
- -- style flags: 0
- -- line height: 16
- -- part name: 1
- ----- HyperTalk script -----
- on mouseUp
- get the length of field "Sum"
- if it is 2 then exit mouseUp
- add 1 to it
- put "1" into char it of field "Sum"
- end mouseUp
-
-
-
- -- part 11 (button)
- -- low flags: 00
- -- high flags: 8003
- -- rect: left=395 top=241 right=273 bottom=428
- -- title width / last selected line: 0
- -- icon id / first selected line: 0 / 0
- -- text alignment: 1
- -- font id: 0
- -- text size: 12
- -- style flags: 0
- -- line height: 16
- -- part name: 2
- ----- HyperTalk script -----
- on mouseUp
- get the length of field "Sum"
- if it is 2 then exit mouseUp
- add 1 to it
- put "2" into char it of field "Sum"
- end mouseUp
-
-
-
- -- part 12 (button)
- -- low flags: 00
- -- high flags: 8003
- -- rect: left=436 top=242 right=274 bottom=468
- -- title width / last selected line: 0
- -- icon id / first selected line: 0 / 0
- -- text alignment: 1
- -- font id: 0
- -- text size: 12
- -- style flags: 0
- -- line height: 16
- -- part name: 3
- ----- HyperTalk script -----
- on mouseUp
- get the length of field "Sum"
- if it is 2 then exit mouseUp
- add 1 to it
- put "3" into char it of field "Sum"
- end mouseUp
-
-
-
- -- part 13 (button)
- -- low flags: 00
- -- high flags: 8003
- -- rect: left=355 top=281 right=313 bottom=407
- -- title width / last selected line: 0
- -- icon id / first selected line: 0 / 0
- -- text alignment: 1
- -- font id: 0
- -- text size: 12
- -- style flags: 0
- -- line height: 16
- -- part name: 0
- ----- HyperTalk script -----
- on mouseUp
- get the length of field "Sum"
- if it is 2 then exit mouseUp
- add 1 to it
- put "0" into char it of field "Sum"
- end mouseUp
-
-
-
- -- part 14 (button)
- -- low flags: 00
- -- high flags: 8003
- -- rect: left=414 top=281 right=313 bottom=468
- -- title width / last selected line: 0
- -- icon id / first selected line: 0 / 0
- -- text alignment: 1
- -- font id: 0
- -- text size: 12
- -- style flags: 0
- -- line height: 16
- -- part name: Enter
- ----- HyperTalk script -----
- on mouseUp
- global answer
- if field "SUM" < 1 then exit mouseUp
- if field "Flag" > 0 then exit mouseUp
- put field "Addend1" into answer
- add field "Addend2" to answer
- add 1 to field "Attempts"
- if field "Sum" = answer then
- add 1 to field "Correct"
- get field "Correct"
- divide it by field "Attempts"
- multiply it by 100
- put round(it) into field "Percent"
- celebrate
- else
- get field "Correct"
- divide it by field "Attempts"
- multiply it by 100
- put round(it) into field "Percent"
- nag
- end if
- end mouseUp
-
- on celebrate
- put "Correct" into line 1 of field "Comment"
- put first word of bkgnd field "Name" into line 2 of field "Comment"
- hide button "Smiley"
- put "1" into field "Flag"
- if first word of bkgnd field "Options" = "Y" then
- play "Harpsichord" tempo 200 "g4e c5 e gh eq gh"
- end if
- end celebrate
-
- on nag
- global answer
- put "WRONG!" into line 1 of field "Comment"
- put "The answer is "& answer & "." into line 3 of field "Comment"
- hide button "Frowney"
- put "2" into field "Flag"
- if first word of bkgnd field "Options" = "Y" then
- play "boing" tempo 200 "gq c e a"
- end if
- end nag
-
-
-
- -- part 15 (button)
- -- low flags: 00
- -- high flags: 0001
- -- rect: left=33 top=190 right=281 bottom=132
- -- title width / last selected line: 0
- -- icon id / first selected line: 0 / 0
- -- text alignment: 1
- -- font id: 0
- -- text size: 12
- -- style flags: 0
- -- line height: 16
- -- part name: Smiley
-
-
- -- part 16 (button)
- -- low flags: 00
- -- high flags: 0001
- -- rect: left=226 top=195 right=288 bottom=329
- -- title width / last selected line: 0
- -- icon id / first selected line: 0 / 0
- -- text alignment: 1
- -- font id: 0
- -- text size: 12
- -- style flags: 0
- -- line height: 16
- -- part name: Frowney
-
-
- -- part contents for background part 1
- ----- text -----
-
-
- -- part contents for background part 2
- ----- text -----
-
-
- -- part contents for background part 4
- ----- text -----
- 1
-
- -- part contents for background part 6
- ----- text -----
- O
-
- -- part contents for background part 7
- ----- text -----
- O
-
- -- part contents for background part 8
- ----- text -----
- O
-
- -- part contents for background part 10
- ----- text -----
- Y 5 2
-
- -- part contents for background part 11
- ----- text -----
- larry